<!DOCTYPE html> 
<html>
  <head>
    <title>Bytown Lumberjack</title>

    <link rel="stylesheet" href="../Common/browser.css">
    <link rel="stylesheet" href="lumberjack.css">

    <meta http-equiv="X-UA-Compatible" content="IE=edge">
  </head>
  <body onload="onLoad()">
    <script type="text/javascript">
      var jsilConfig = {
        printStackTrace: false,
        webgl2d: true,
        xna: 4,
        gamepad: true,
        localStorage: true,
        readOnlyStorage: true,

        manifests: [
          "Lumberjack.exe",
          "Content/LumberjackContent.contentproj"
        ],
        
        showProgressBar: true,
        showStats: true,
        showFullscreenButton: true,

        scriptRoot: "",
        libraryRoot: "../Libraries/",
        fileRoot: "Content/",
        contentRoot: "Content/"
      };
    </script>
    <script src="../Libraries/JSIL.js" type="text/javascript"></script>    
    
    <canvas id="canvas" width="1280" height="720">
    </canvas><br>

    <div id="welcomeMessage">
      <p align="center"><a href="http://jsil.org/"><img src="http://jsil.org/images/jsil_48px.png" alt="JSIL logo" border="0"></a></p>
    </div>
    <div id="log"><center><span style="font-size: 16pt; text-align: center; display: inline-block">
      Arrow keys to move. Z for light attack, X for heavy attack. Escape to cancel.<br>
      <a href="http://www.luminance.org/blog/code/2012/04/14/bytown-lumberjack-html5-behind-the-scenes">Click here for info on how this port was made</a>.
    </span></center><br></div>

    <script type="text/javascript">
      var assetsToLoad = [
        // Used to read the levels
        ["Script", "Lumberjack.XmlSerializers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null.js", { "sizeBytes": 446704 }],
      ];

      function runMain () {
        try {
          document.getElementById("welcomeMessage").setAttribute("style", "display: none");
        } catch (ex) {
        }

        // We can't invoke Main() since it disposes the Game immediately, breaking everything.
        var asm = JSIL.GetAssembly("Lumberjack, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null", true);
        asm.Lumberjack.Globals.DEBUG = false;
        var game = new asm.Lumberjack.Lumberjack();
        game.Run();
      };
    </script>
    <script type="text/javascript">
    var _gaq = _gaq || [];
    _gaq.push(['_setAccount', 'UA-6375004-2']);
    _gaq.push(['_setDomainName', '.luminance.org']);
    _gaq.push(['_trackPageview']);

    (function() {
      var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
      ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
      var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
    })();
    </script>
  </body>
</html>
